home *** CD-ROM | disk | FTP | other *** search
Text File | 1996-09-17 | 2.6 KB | 100 lines | [TEXT/MPS ] |
- //========================================================================================
- //
- // File: PRPictur.h
- // Release Version: $ ODF 2 $
- //
- // Copyright: (c) 1993 - 1996 by Apple Computer, Inc., all rights reserved.
- //
- //========================================================================================
-
- #ifndef PRPICTUR_H
- #define PRPICTUR_H
-
- #ifndef FWSTDDEF_H
- #include "FWStdDef.h"
- #endif
-
- #ifndef SLGRDEF_H
- #include "SLGrDef.h"
- #endif
-
- #ifndef SLPTRECT_H
- #include "SLPtRect.h"
- #endif
-
- #ifndef PRGRREF_H
- #include "PRGrRef.h"
- #endif
-
- //========================================================================================
- // Forward Declarations
- //========================================================================================
-
- class FW_OResourceFile;
-
- class FW_CReadableStream;
- class FW_CWritableStream;
-
- struct FW_SGraphicContext;
-
- //========================================================================================
- // class FW_CPrivPictureRep
- //========================================================================================
-
- class FW_CPrivPictureRep : public FW_CPrivGrRefObj
- {
- public:
- FW_DECLARE_AUTO(FW_CPrivPictureRep)
-
- //----------------------------------------------------------------------------------------
- // Constructors/Destructors
- //
-
- FW_CPrivPictureRep(FW_CReadableStream& stream);
- FW_CPrivPictureRep(FW_OResourceFile* resourceFile, FW_ResourceID resID);
- FW_CPrivPictureRep(FW_PlatformPict platformPict);
- FW_CPrivPictureRep(const FW_CPrivPictureRep& other);
-
- ~FW_CPrivPictureRep();
-
- void Write(FW_CWritableStream& stream);
- FW_Boolean IsEqual(const FW_CPrivPictureRep& other) const;
-
- //----------------------------------------------------------------------------------------
- // Bounds
-
- void GetPictBounds(FW_SRect& bounds) const;
- void GetPictBoundsGC(Environment* ev, FW_SGraphicContext& gc, FW_SRect& bounds) const;
-
- //----------------------------------------------------------------------------------------
- // Handle operations
-
- FW_PlatformPict GetPlatformPict() const;
- FW_Boolean IsPlatformPictOrphan() const;
- FW_PlatformPict OrphanPlatformPict();
-
- void SetPlatformPict(FW_PlatformPict newPict);
- void AdoptPlatformPict(FW_PlatformPict newPict);
-
- //----------------------------------------------------------------------------------------
- // Macintosh specific
-
- #ifdef FW_BUILD_MAC
- void MacLock();
- void MacUnlock();
- #endif
-
- private:
- void PrivReadFrom(FW_CReadableStream& stream);
- void PrivDisposePict();
-
- FW_Boolean fOwnPicture;
- FW_PlatformPict fPlatformPict;
-
- #ifdef FW_BUILD_MAC
- short fMacLockCount;
- #endif
- };
-
- #endif // PRPICTUR_H
-